package com.eascs.web.o2o.report.quartz;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.eascs.app.log.Logger;
import com.eascs.app.log.LoggerFactory;
import com.eascs.web.o2o.quartz.util.BaseJobUtil;
import com.eascs.web.o2o.quartz.util.ExecutorService;
import com.eascs.web.o2o.report.service.FefundService;
import com.eascs.web.o2o.report.service.MessageEmailServiceImpl;

@Component("O2oMSGQuartz")
public class O2oMSGQuartz extends BaseJobUtil {
	protected final Logger logger = LoggerFactory.getLogger(getClass());
	@Autowired
	FefundService fefundService;

	@Autowired
	MessageEmailServiceImpl messageEmailServiceImpl;

	public void findNewFundFKS() { // 国安村镇新老系统放款日当天发送
		executor("O2oMSGQuartz", "findNewFundFKS", "每一小时查询一次,国安村镇放款日当天发送短信队列生成任务", new ExecutorService() {
			@Override
			public void exe() {
				fefundService.findNewFundFKS();
			}
		});
	}

	public void findFundBeforeOneDay() { // 新老系统付息日前两天
		executor("O2oMSGQuartz", "findFundBeforeOneDay", "每天上午 8点55执行,付息日前两天短信队列生成任务", new ExecutorService() {
			@Override
			public void exe() {
				fefundService.GACZFundBeforeDay(2);
			}
		});
	}


}
